package com.ltx.mcpserver.service;

import org.springframework.ai.tool.annotation.Tool;
import org.springframework.ai.tool.annotation.ToolParam;
import org.springframework.stereotype.Service;

/**
 * @author 罗添煦
 * @description
 * @create 2025-04-22 下午12:34
 */
@Service
public class WeatherService {
    @Tool(description = "获取城市温度")
    public String getWeather(@ToolParam(description = "城市名") String city) {
        return city + "温度为" + Math.random() * 100;
    }
}
